package com.baofu.paycore.common.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 业务指令类型
 *
 * User: xin deng  Date: 16/7/5 ProjectName: paycore Version: 1.0
 */
@Getter
@AllArgsConstructor
public enum BizCmdTypeEnum {

    ACC_UNFREEZE("ACC_UNFREEZE", "账务解冻处理"),

    CLEAR_TIME_OUT("CLEAR_TIME_OUT", "清分超时处理"),

    ADVANCE_ORDER("ADVANCE_ORDER", "补单处理"),

    ACC_RETRY("ACC_RETRY", "账务指令重试");

    /**
     * 编码
     */
    private String code;

    /**
     * 描述
     */
    private String desc;

    public static String explain(String bizType){
        for (BizCmdTypeEnum bizCmdTypeEnum : values()){
            if(bizCmdTypeEnum.getCode().equals(bizType)){
                return bizCmdTypeEnum.getDesc();
            }
        }
        return null;
    }

}
